﻿using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.Data;
using System.Drawing;
using System.Linq;
using System.Text;
using System.Windows.Forms;

namespace WindowsFormProject
{
    public partial class HesapPlanSeciciForm : Form
    {
        int _SatirNo = 0;
        public HesapPlanSeciciForm(int SatirNo)
        {
            InitializeComponent();
            _SatirNo = SatirNo;
        }
        DBBaglantiDataContext db = new DBBaglantiDataContext();
        private void HesapPlanSeciciForm_Load(object sender, EventArgs e)
        {
            var sorgu = (from x in db.HesapPlanis select x).ToList();
            dataGridView1.DataSource = sorgu;
        }

        private void dataGridView1_CellContentDoubleClick(object sender, DataGridViewCellEventArgs e)
        {
            MahsupFisiFrm frm = Application.OpenForms["MahsupFisiFrm"] as MahsupFisiFrm;
            frm.dataGridView1.Rows[_SatirNo].Cells[1].Value = dataGridView1.Rows[e.RowIndex].Cells[0].Value;
            this.Close();





        }
    }
}
